package com.jdrx.sw.sewage.service.base;

import com.jdrx.platform.commons.rest.exception.BizException;
import org.apache.commons.lang3.StringUtils;
import org.springframework.stereotype.Service;

@Service
public class BaseServiceImpl {


    /**
     * 根据租户id获取sql前缀
     *
     * @param dataNode
     * @return
     * @throws BizException
     */
    protected String getSQLPerfix(String dataNode) throws BizException {
//        Asserts.notBlank(dataNode, "租户id");
        if (StringUtils.isEmpty(dataNode)) return null;
        return "/*!mycat:schema = " + dataNode + "*/";
    }
}
